﻿using System.Collections.Generic;
using Resolve.FlagInfo;

namespace Resolve.Contracts
{
    public interface ICodeCompiler
    {
        /// <summary>
        /// 编译文件
        /// </summary>
        /// <param name="source"></param>
        /// <param name="viewData"></param>
        /// <param name="model"></param>
        FlagCodeInFile CompileFile(string source, IDictionary<string, object> viewData, IDictionary<string, object> model);

        /// <summary>
        /// 编译目录下的文件根据文件路径
        /// </summary>
        /// <param name="source"></param>
        /// <param name="viewData"></param>
        /// <param name="model"></param>
        FlagCodeInFile CompileFloderFromFilePath(string source, IDictionary<string, object> viewData, IDictionary<string, object> model);
    }
}
